/*	kd:
	This guy exists for testing only, because I load the shop on top of gc, so
	I cannot modify gc's player pawn to include structs I make here, and I
	really don't wanna mud up my gc folder now... */

class Shopcaster : Guncaster replaces Guncaster {
	Gc_Binds        Binds;
	Gc_SpellCycle   SpellCycle;
	
	void ShopBind (uint bind, Gcs_ItemType handler, class <Inventory> item) {
		Binds.Set(bind, handler, item);
	}
	
	void NextSpell () {
		/* bool changed = */SpellCycle.Next();
		
		/* if(changed) {
		} */
	}
	
	void PrevSpell () {
		/*bool changed = */SpellCycle.Prev();
		
		/*if(changed) {
		}*/
	}
	
	override void Tick () {
		Super.Tick();
		HandleBinds();
	}
	
	// The binds you set in the shop / spell wheel.
	
	void HandleBinds () {
		// Since the user keys are the same for setting as well as binding,
		// we really don't wanna activate a bind in the shop.
		if(1 <= CountInv("MenuWheelActive")) {
			return;
		}
		
		uint press =
			GetPlayerInput(INPUT_BUTTONS) & (~GetPlayerInput(INPUT_OLDBUTTONS));
		
				if(press & BT_USER1)	Binds.Use(0);
		else	if(press & BT_USER2)	Binds.Use(1);
		else	if(press & BT_USER3)	Binds.Use(2);
		else	if(press & BT_USER4)	Binds.Use(3);
	}
}